home *** CD-ROM | disk | FTP | other *** search
/ Programmers Heaven 2 / Programmers Heaven 2.iso / files / graphics / library / wgt51_r2.zip / WGT5 / H / WGTFLIC.H < prev    next >
Encoding:
C/C++ Source or Header  |  1996-08-03  |  2.7 KB  |  69 lines

  1. #ifndef _WGTFLIC_
  2. #define _WGTFLIC_
  3.  
  4. #include <wgt5.h>
  5.  
  6. /*
  7.    WordUp Graphics Toolkit V5.0  FLI/FLC Routines
  8.    Copyright 1995 Egerter Software
  9. */
  10.  
  11. #ifdef __cplusplus
  12.   extern "C" {
  13. #endif
  14.  
  15. typedef struct {                        /* MAIN FLI header */
  16.     int         size;                   /* Size of file */
  17.     unsigned short magic;               /* 44817 = FLI, 44818 = FLC */
  18.     short       frames;                 /* Frames in animation */
  19.     short       width;                  /* Animation width */
  20.     short       height;                 /* Animation height */
  21.     short       depth;                  /* Bits per pixel (8) */
  22.     short       flags;                  /* Set to 0x0003 after ring frame */
  23.     short       speed;                  /* Delay in msec between frames */
  24.     short       reserved;               /* Unused word, set to 0 */
  25.     int         created;                /* MSDOS format date/time */
  26.     int         creator;                /* Serial # of AnimPro */
  27.     int         updated;                /* MSDOS format date/time */
  28.     int         updater;                /* Yet another serial # */
  29.     short       aspectx;                /* Aspect ratio of x-axis */
  30.     short       aspecty;                /* Aspect ratio of y-axis */
  31.     unsigned short reserved2[19];       /* 38 unused bytes, set to zeroes */
  32.     int         oframe1;                /* Offset of frame 1 in file */
  33.     int         oframe2;                /* Offset of frame 2 in file */
  34.     unsigned short reserved3[20];       /* 40 unused bytes, set to zeroes */
  35. } flicheader;
  36.  
  37. #define FLIC_DISK               0
  38. #define FLIC_MEMORY             1
  39.  
  40. #define FLIC_IGNOREPALETTE      0
  41. #define FLIC_UPDATEPALETTE      1
  42.  
  43. #define FLIC_OK                 0
  44. #define FLIC_NOTFOUND           1
  45. #define FLIC_INVALIDRES         2
  46. #define FLIC_INVALIDHEADER      3
  47. #define FLIC_INVALIDFRAME       4
  48. #define FLIC_INVALIDCHUNK       5
  49. #define FLIC_DONE               6
  50.  
  51. extern flicheader flichdr;      /* Access this structure for general info */
  52.  
  53. extern block    flicscreen;     /* Logical screen for FLI/FLC updates */
  54. extern int      flic_updatey;   /* Uppermost y position updated */
  55. extern int      flic_updatey2;  /* Lowermost y position updated */
  56. extern int      flic_update;    /* Indicates screen update */
  57.  
  58.                                 /* Open up a FLI or FLC file */
  59. int   openflic (char *filename, int mode_flic, int update_colors);
  60. int   nextframe (void);         /* Advance to the next frame */
  61. void  copyflic (void);          /* Copy the FLICSCREEN to the visual screen */
  62. void  closeflic (void);         /* Close the FLI/FLC file */
  63.  
  64. #ifdef __cplusplus
  65. }
  66. #endif
  67.  
  68. #endif
  69.